package com.example.bishe.demos.web;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class hello {
//    @GetMapping("/hi")
    //http://localhost:8080/hi?nickname=zhangsan&phone=123
    @RequestMapping (value="/hi",method = RequestMethod.GET)
    public String hi(String nickname,String phone){
        System.out.println(phone);
        return"hello world" + nickname;
    }
}
